package demo1.subClass;

import demo1.Duck;
import demo1.FlyBehavior;
import demo1.QuackBehavior;
import demo1.impl.MuteQuack;
import demo1.impl.NoFlyWay;
import demo1.impl.Squeak;

/**
 * @author 24岁没牵过女人的手
 * 日期：2023/6/19 16:18
 * 文件描述：
 */
public class RubberDuck extends Duck {

    public RubberDuck() {
        super(new Squeak(), new NoFlyWay());
    }

    @Override
    public void disPlay() {
        System.out.println("橡胶");
    }

    @Override
    public void swim() {
        super.swim();
    }
}
